#!/usr/bin/python
#coding:utf-8
__author__ = 'Metersbonwe'

from tkintertable import *
import mpsan

def startButton():
    statusText.set("播放音乐")
    musicText.set("正在播放 ：Faded.flac")
    mpsan.start()

def stopButton():
    statusText.set("停止音乐")
    musicText.set("没有在播放的歌曲")
    mpsan.stop()

window = Tk()
window.title("MP3播放器 - v1.1")
window.geometry('400x400')

statusText = StringVar()

musicText = StringVar()

btn1 = Button(window, text='播放', width=6, height=3, bg='green', command=startButton).grid(row=0,column=0)
btn2 = Button(window, text='暂停', width=6, height=3, bg='red', command=stopButton).grid(row=0,column=1)
lab = Label(window, textvariable=statusText, width=10).grid(row=0,column=2)
musicLab = Label(window, textvariable=musicText, width=30, height=3, bg='gray').grid(row=0,column=3)


window.mainloop()